package org.example.test;

import org.example.annotation.NavigationCase;
import org.example.annotation.NavigationCases;
import org.example.annotation.Operation;
import org.example.enums.InstanceStrategy;

@Operation(InstanceStrategy.PROTOTYPE)
public class MyOperation {

	@NavigationCases({ 
		@NavigationCase(id = "success", url = "ok.jsp"),
		@NavigationCase(id = "fail", url = "ohno.jsp") })
	public void insert() {
		throw new RuntimeException("something");
	}
	
	@NavigationCases({ 
		@NavigationCase(id = "success", url = "ok.jsp"),
		@NavigationCase(id = "fail", url = "ohno.jsp") })
	public void update() {
		System.out.println("Completing code");
	}
}
